/*
 * MainWindow.java
 *
 * Created on 7 de Dezembro de 2007, 01:27
 */
package org.ontoscheduler.ui;

import com.hp.hpl.jena.ontology.Individual;
import com.hp.hpl.jena.ontology.OntModel;
import com.hp.hpl.jena.rdf.model.Literal;
import com.hp.hpl.jena.rdf.model.Property;
import com.hp.hpl.jena.rdf.model.Resource;
import com.toedter.calendar.JDateChooser;
import java.awt.Color;
import java.io.File;
import java.util.ArrayList;
import java.util.Date;
import java.util.Iterator;
import java.util.UUID;
import javax.swing.ButtonGroup;
import javax.swing.DefaultListModel;
import javax.swing.JCheckBox;
import javax.swing.JComboBox;
import javax.swing.JFileChooser;
import javax.swing.JLabel;
import javax.swing.JList;
import javax.swing.JRadioButton;
import javax.swing.JTextField;
import javax.swing.ListModel;
import org.ontoscheduler.concepts.Concepts;
import org.ontoscheduler.jenaontologymanager.JenaOntologyManager;

/**
 *
 * @author  joaoolavo
 */
public class MainWindow extends javax.swing.JFrame {

    private JenaOntologyManager jena = null;
    private Integer COUNTER_AGENT = new Integer(1);
    private Integer COUNTER_INTERNALCOMM = new Integer(1);
    private Integer COUNTER_SOCIALCOMM = new Integer(1);
    private Integer COUNTER_ACTIONFO = new Integer(1);
    private Integer COUNTER_ACTIONHO = new Integer(1);
    private int KEY_ENTER = 10;
    protected static int DATATYPE_PROPERTY = 0;
    protected static int OBJECT_PROPERTY = 1;
    private JFileChooser fc = new JFileChooser();
    private File selFile = null;

    /** Creates new form MainWindow */
    public MainWindow() {

        initComponents();
        
        TabWindow.setVisible(false);

        agentInternalCommitment.setModel(new DefaultListModel());
        agentSocialCommitment.setModel(new DefaultListModel());
        socialCommitmentAgents.setModel(new DefaultListModel());
        actionFOInternalCommitment.setModel(new DefaultListModel());
        actionFOSocialCommitment.setModel(new DefaultListModel());
        actionHOActionFO.setModel(new DefaultListModel());

        internalCommitmentActionFO.removeAllItems();
        internalCommitmentAgent.removeAllItems();
        socialCommitmentActionFO.removeAllItems();
        actionFOActionHO.removeAllItems();
        socialCommitmentAgentCombo.removeAllItems();
    }
    
    private void reloadAllTabs(){
        agentIndividualsMouseClicked(null);
        internalCommitmentIndividualsMouseClicked(null);
        socialCommitmentIndividualsMouseClicked(null);
        actionFOIndividualsMouseClicked(null);
        actionHOIndividualsMouseClicked(null);
    }
    
    private boolean isOntSaved(){
        if(selFile != null)
            return true;
        else
            return false;
    }
    
    private boolean isOntLoaded(){
        return TabWindow.isVisible();
    }
    
    private void setOntLoaded(boolean option, boolean defaultFile){
            TabWindow.setVisible(option);
            
            if(option == false){
                selFile = null;
                jena = null;
            }
            else{
                if(defaultFile == true)
                    jena = new JenaOntologyManager();
                else
                    jena = new JenaOntologyManager(selFile);
                loadInvidivuals();
            }
    }
    
    private void loadInvidivuals(){
        loadIndividuals(jena.agent, agentIndividuals);
        loadIndividuals(jena.internalCommitment, internalCommitmentIndividuals);
        loadIndividuals(jena.socialCommitment, socialCommitmentIndividuals);
        loadIndividuals(jena.actionUniversalFO, actionFOIndividuals);
        loadIndividuals(jena.actionUniversalHO, actionHOIndividuals);
        reloadAllTabs();
    }

    private void loadIndividuals(Concepts c, JList list) {
        DefaultListModelWithIndividual listModel = new DefaultListModelWithIndividual();
        list.setModel(listModel);
        Iterator i = c.listIndividuals();
        while (i.hasNext()) {
            Individual ind = (Individual) i.next();
            listModel.addElement(ind);
        }
    }

    private void addButton(Concepts concept, String conceptName, Integer COUNTER, JList listIndividuals, JTextField fieldName) {
        String name = conceptName + COUNTER;
        Individual ind = concept.addIndividual(name);
        DefaultListModelWithIndividual m = (DefaultListModelWithIndividual) listIndividuals.getModel();
        m.addElement(ind);
        listIndividuals.setSelectedIndex(m.getSize() - 1);
        fieldName.setText(name);
    }

    private void loadPropertyList(JList propertyList, Concepts concept, Individual ind, String propertyName) {
        DefaultListModel m = (DefaultListModel) propertyList.getModel();
        m.removeAllElements();

        Iterator iter = concept.getPropertyValues(propertyName, ind);
        while (iter.hasNext()) {
            Resource r = (Resource) iter.next();
            OntModel ontmodel = (OntModel) r.getModel();
            Individual i = ontmodel.getIndividual(r.getURI());
            m.addElement(i.getLabel(null));
        }
    }

    private void loadComboBox(JComboBox combo, Concepts conceptDomain, Concepts conceptRange, Individual ind, String propertyName, JList listSource) {
        combo.removeAllItems();

        if(conceptRange != null){
            Iterator iter = conceptRange.listIndividuals();
            while (iter.hasNext()) {
                Resource r = (Resource) iter.next();
                OntModel ontmodel = (OntModel) r.getModel();
                Individual i = ontmodel.getIndividual(r.getURI());
                combo.insertItemAt(i.getLabel(null), combo.getItemCount());
            }
        }
        else{
            ListModel listModel = listSource.getModel();
            for(int i = 0; i < listModel.getSize(); i++){
                combo.insertItemAt(listModel.getElementAt(i), i);
            }
        }

        Iterator value = conceptDomain.getPropertyValues(propertyName, ind);
        if (value.hasNext()) {
            Resource r = (Resource) value.next();
            OntModel ontmodel = (OntModel) r.getModel();
            Individual i = ontmodel.getIndividual(r.getURI());
            combo.setSelectedItem(i.getLabel(null));
        }
    }

    private void saveName(JList individuals, JTextField nameField, Concepts concept) {
        int selectedIndex = individuals.getSelectedIndex();
        if (selectedIndex == -1) {
            return;
        }
        String name = nameField.getText();

        DefaultListModelWithIndividual model = (DefaultListModelWithIndividual) individuals.getModel();
        model.setElementAt(name, selectedIndex);

        Individual ind = model.getIndividual(selectedIndex);
        jena.agent.setIndividualName(ind, name);
    }

    private void saveList(JList individualsDomain, JList list, JList individualsRange, Concepts concept, String propertyName) {
        int selectedIndex = individualsDomain.getSelectedIndex();
        if (selectedIndex == -1) {
            return;
        }

        Individual ind = ((DefaultListModelWithIndividual) individualsDomain.getModel()).getIndividual((String) individualsDomain.getSelectedValue());
        ArrayList valueList = new ArrayList();
        DefaultListModelWithIndividual modelRange = (DefaultListModelWithIndividual) individualsRange.getModel();
        DefaultListModelWithIndividual modelDomain = (DefaultListModelWithIndividual) individualsDomain.getModel();
        for (int i = 0; i < list.getModel().getSize(); i++) {
            Individual v = modelRange.getIndividual((String) list.getModel().getElementAt(i));
            valueList.add(v);
        }
        concept.addPropertyValues(propertyName, ind, valueList, OBJECT_PROPERTY);
    }

    private void saveComboBox(JList individualsDomain, JComboBox combo, JList individualsRange, Concepts concept, String propertyName) {
        int selectedIndex = individualsDomain.getSelectedIndex();
        if (selectedIndex == -1) {
            return;
        }

        Individual ind = ((DefaultListModelWithIndividual) individualsDomain.getModel()).getIndividual((String) individualsDomain.getSelectedValue());
        ArrayList valueList = new ArrayList();
        DefaultListModelWithIndividual modelRange = (DefaultListModelWithIndividual) individualsRange.getModel();
        String valueName = (String) combo.getSelectedItem();
        Individual value = modelRange.getIndividual(valueName);
        if (value != null) {
            valueList.add(value);
            concept.addPropertyValues(propertyName, ind, valueList, OBJECT_PROPERTY);
            combo.setSelectedIndex(combo.getSelectedIndex());
        }
    }

    private void addDate(Concepts conceptDomain, Concepts conceptRange, Individual indRange, String nameDomain, String propertyName) {
        Individual indValue = conceptRange.addIndividual(nameDomain + indRange.getLabel(null) + UUID.randomUUID().toString());
        ArrayList l = new ArrayList();
        l.add(indValue);

        conceptDomain.addPropertyValues(propertyName, indRange, l, OBJECT_PROPERTY);
        conceptRange.addPropertyValue("begin", indValue, new Date(), DATATYPE_PROPERTY);
        conceptRange.addPropertyValue("end", indValue, new Date(), DATATYPE_PROPERTY);
    }

    private void loadDate(JList individuals, Concepts concept, JDateChooser beginField, JDateChooser endField, String propertyName) {
        DefaultListModelWithIndividual model = (DefaultListModelWithIndividual) individuals.getModel();
        Individual ind = model.getIndividual(individuals.getSelectedIndex());

        Property p = ind.getOntModel().getProperty(concept.ns, propertyName);
        Resource r = (Resource) ind.getPropertyValue(p);
        OntModel ontmodel = (OntModel) r.getModel();
        Individual i = ontmodel.getIndividual(r.getURI());

        Iterator beginValue = concept.getPropertyValues("begin", i);
        Literal b = (Literal) beginValue.next();
        beginField.setDate((Date)b.getValue());

        Iterator endValue = concept.getPropertyValues("end", i);
        Literal e = (Literal) endValue.next();
        endField.setDate((Date)e.getValue());
    }

    private void saveDate(JList individuals, Concepts concept, JDateChooser beginField, JDateChooser endField, String propertyName) {
        int selectedIndex = individuals.getSelectedIndex();
        if (selectedIndex == -1) {
            return;
        }

        DefaultListModelWithIndividual model = (DefaultListModelWithIndividual) individuals.getModel();
        Individual ind = model.getIndividual(individuals.getSelectedIndex());

        Property p = ind.getOntModel().getProperty(concept.ns, propertyName);
        Resource r = (Resource) ind.getPropertyValue(p);
        OntModel ontmodel = (OntModel) r.getModel();
        Individual i = ontmodel.getIndividual(r.getURI());

        if (propertyName.equals("inv-causedBy")) {
            jena.actionContribution.setBeginTime(i, beginField.getDate());
            jena.actionContribution.setEndTime(i, endField.getDate());
        } else {
            jena.appointmentGoal.setBeginTime(i, beginField.getDate());
            jena.appointmentGoal.setEndTime(i, endField.getDate());
        }
    }

    private void defineStatus(JDateChooser plannedStart, JDateChooser plannedEnd,
            JDateChooser actualStart, JDateChooser actualEnd, JLabel status,
            ButtonGroup buttonGroupPlanned, JRadioButton plannedRB, ButtonGroup buttonGroupStatus, JRadioButton doneRB, JCheckBox dismissCB){

        if(dismissCB.isSelected()){
            status.setForeground(new Color(115, 174, 187));
            status.setText("Desfeito");
            return;
        }
        
        Date dPlannedStart = plannedStart.getDate();
        Date dPlannedEnd = plannedEnd.getDate();
        Date dActualStart = actualStart.getDate();
        Date dActualEnd = actualEnd.getDate();
        Date dNow = new Date();
        
        //if(dismissed) ...
        //else
            if(buttonGroupPlanned.isSelected(plannedRB.getModel())){
                if(buttonGroupStatus.isSelected(doneRB.getModel())){
                    if ((dActualEnd.after(dPlannedStart) || dActualEnd.equals(dPlannedStart)) &&
                        (dActualEnd.before(dPlannedEnd) || dActualEnd.equals(dPlannedEnd))){
                        status.setForeground(new Color(0, 204, 0));
                        status.setText("Cumprido");
                    } else{
                        status.setForeground(new Color(255, 0, 0));
                        status.setText("Quebrado");
//                        System.out.println(dActualStart.toString() + " " + dActualEnd.toString() + " " + dActualStart.toString() + " " + dPlannedStart.toString() + " " + dPlannedEnd.toString());
                    }
                } else{
                    if(dNow.before(dPlannedEnd) || dNow.equals(dPlannedEnd)){
                        status.setForeground(new Color(153, 153, 0));
                        status.setText("Pendente");
                    } else{
                        status.setForeground(new Color(255, 0, 0));
                        status.setText("Quebrado");
                    }
                }
            } else{
                status.setText("");
            }
        
    }

    /** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        internalCommitmentStatusButtonGroup = new javax.swing.ButtonGroup();
        socialCommitmentStatusButtonGroup = new javax.swing.ButtonGroup();
        internalCommitmentProgrammedButtonGroup = new javax.swing.ButtonGroup();
        socialCommitmentProgrammedButtonGroup = new javax.swing.ButtonGroup();
        jSeparator1 = new javax.swing.JSeparator();
        jMenuItem4 = new javax.swing.JMenuItem();
        jMenuItem5 = new javax.swing.JMenuItem();
        jSeparator2 = new javax.swing.JSeparator();
        TabWindow = new javax.swing.JTabbedPane();
        agentPanel = new javax.swing.JPanel();
        scrollAgent = new javax.swing.JScrollPane();
        agentIndividuals = new javax.swing.JList();
        agentAdd = new javax.swing.JButton();
        agentDataPanel = new javax.swing.JPanel();
        jScrollPane1 = new javax.swing.JScrollPane();
        agentInnerPanel = new javax.swing.JPanel();
        jLabel1 = new javax.swing.JLabel();
        agentName = new javax.swing.JTextField();
        jLabel2 = new javax.swing.JLabel();
        jScrollPane2 = new javax.swing.JScrollPane();
        agentInternalCommitment = new javax.swing.JList();
        jLabel4 = new javax.swing.JLabel();
        jScrollPane3 = new javax.swing.JScrollPane();
        agentSocialCommitment = new javax.swing.JList();
        agentSave = new javax.swing.JButton();
        internalCommPanel = new javax.swing.JPanel();
        scrollAgent1 = new javax.swing.JScrollPane();
        internalCommitmentIndividuals = new javax.swing.JList();
        internalCommitmentAdd = new javax.swing.JButton();
        internalCommitmentDataPanel = new javax.swing.JPanel();
        jScrollPane4 = new javax.swing.JScrollPane();
        internalCommitmentInnerPanel = new javax.swing.JPanel();
        jLabel3 = new javax.swing.JLabel();
        internalCommitmentName = new javax.swing.JTextField();
        jLabel5 = new javax.swing.JLabel();
        jLabel6 = new javax.swing.JLabel();
        internalCommitmentAgent = new javax.swing.JComboBox();
        internalCommitmentActionFO = new javax.swing.JComboBox();
        jLabel17 = new javax.swing.JLabel();
        jLabel18 = new javax.swing.JLabel();
        jLabel19 = new javax.swing.JLabel();
        internalCommitmentFulfilled = new javax.swing.JRadioButton();
        internalCommitmentStatus = new javax.swing.JLabel();
        jLabel21 = new javax.swing.JLabel();
        jLabel22 = new javax.swing.JLabel();
        internalCommitmentUnfulfilled = new javax.swing.JRadioButton();
        internalCommitmentPlannedStartCalendar = new com.toedter.calendar.JDateChooser();
        internalCommitmentPlannedEndCalendar = new com.toedter.calendar.JDateChooser();
        internalCommitmentActualStartCalendar = new com.toedter.calendar.JDateChooser();
        internalCommitmentActualEndCalendar = new com.toedter.calendar.JDateChooser();
        internalCommitmentProgramed = new javax.swing.JRadioButton();
        internalCommitmentNonProgramed = new javax.swing.JRadioButton();
        internalCommitmentDismiss = new javax.swing.JCheckBox();
        internalCommitmentSave = new javax.swing.JButton();
        socialCommPanel = new javax.swing.JPanel();
        scrollAgent2 = new javax.swing.JScrollPane();
        socialCommitmentIndividuals = new javax.swing.JList();
        socialCommitmentAdd = new javax.swing.JButton();
        socialCommitmentDataPanel = new javax.swing.JPanel();
        jScrollPane5 = new javax.swing.JScrollPane();
        socialCommitmentInnerPanel = new javax.swing.JPanel();
        jLabel7 = new javax.swing.JLabel();
        socialCommitmentName = new javax.swing.JTextField();
        jLabel8 = new javax.swing.JLabel();
        jLabel9 = new javax.swing.JLabel();
        socialCommitmentActionFO = new javax.swing.JComboBox();
        jLabel24 = new javax.swing.JLabel();
        jLabel25 = new javax.swing.JLabel();
        jLabel26 = new javax.swing.JLabel();
        socialCommitmentFulfilled = new javax.swing.JRadioButton();
        socialCommitmentStatus = new javax.swing.JLabel();
        jLabel28 = new javax.swing.JLabel();
        jLabel29 = new javax.swing.JLabel();
        socialCommitmentUnfulfilled = new javax.swing.JRadioButton();
        jScrollPane6 = new javax.swing.JScrollPane();
        socialCommitmentAgents = new javax.swing.JList();
        socialCommitmentAgentCombo = new javax.swing.JComboBox();
        socialCommitmentAgentAdd = new javax.swing.JButton();
        socialCommitmentAgentRemove = new javax.swing.JButton();
        socialCommitmentPlannedStartCalendar = new com.toedter.calendar.JDateChooser();
        socialCommitmentPlannedEndCalendar = new com.toedter.calendar.JDateChooser();
        socialCommitmentActualStartCalendar = new com.toedter.calendar.JDateChooser();
        socialCommitmentActualEndCalendar = new com.toedter.calendar.JDateChooser();
        socialCommitmentNonProgramed = new javax.swing.JRadioButton();
        socialCommitmentProgramed = new javax.swing.JRadioButton();
        jLabel15 = new javax.swing.JLabel();
        socialCommitmentResponsable = new javax.swing.JComboBox();
        socialCommitmentDismiss = new javax.swing.JCheckBox();
        socialCommitmentSave = new javax.swing.JButton();
        actionFOPanel = new javax.swing.JPanel();
        scrollAgent3 = new javax.swing.JScrollPane();
        actionFOIndividuals = new javax.swing.JList();
        actionFOAdd = new javax.swing.JButton();
        actionFODataPanel = new javax.swing.JPanel();
        jScrollPane10 = new javax.swing.JScrollPane();
        actionFOInnerPannel = new javax.swing.JPanel();
        jLabel10 = new javax.swing.JLabel();
        actionFOName = new javax.swing.JTextField();
        jLabel11 = new javax.swing.JLabel();
        jScrollPane7 = new javax.swing.JScrollPane();
        actionFOInternalCommitment = new javax.swing.JList();
        jLabel12 = new javax.swing.JLabel();
        jScrollPane8 = new javax.swing.JScrollPane();
        actionFOSocialCommitment = new javax.swing.JList();
        jLabel30 = new javax.swing.JLabel();
        actionFOActionHO = new javax.swing.JComboBox();
        jLabel16 = new javax.swing.JLabel();
        jLabel20 = new javax.swing.JLabel();
        jLabel23 = new javax.swing.JLabel();
        jLabel27 = new javax.swing.JLabel();
        jProgressBar1 = new javax.swing.JProgressBar();
        jProgressBar2 = new javax.swing.JProgressBar();
        jProgressBar3 = new javax.swing.JProgressBar();
        actionFOSave = new javax.swing.JButton();
        actionHOPanel = new javax.swing.JPanel();
        scrollAgent4 = new javax.swing.JScrollPane();
        actionHOIndividuals = new javax.swing.JList();
        actionHOAdd = new javax.swing.JButton();
        actionHODataPanel = new javax.swing.JPanel();
        jScrollPane13 = new javax.swing.JScrollPane();
        actionHOInnerPanel = new javax.swing.JPanel();
        jLabel13 = new javax.swing.JLabel();
        actionHOName = new javax.swing.JTextField();
        jLabel14 = new javax.swing.JLabel();
        jScrollPane14 = new javax.swing.JScrollPane();
        actionHOActionFO = new javax.swing.JList();
        actionHOSave = new javax.swing.JButton();
        jMenuBar1 = new javax.swing.JMenuBar();
        jMenu1 = new javax.swing.JMenu();
        fileNew = new javax.swing.JMenuItem();
        jSeparator5 = new javax.swing.JSeparator();
        fileOpen = new javax.swing.JMenuItem();
        jSeparator3 = new javax.swing.JSeparator();
        fileSave = new javax.swing.JMenuItem();
        fileSaveAs = new javax.swing.JMenuItem();
        jSeparator4 = new javax.swing.JSeparator();
        fileCloseFile = new javax.swing.JMenuItem();
        fileExit = new javax.swing.JMenuItem();

        jMenuItem4.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_W, java.awt.event.InputEvent.CTRL_MASK));
        jMenuItem4.setText("Fechar arquivo");

        jMenuItem5.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_F4, java.awt.event.InputEvent.ALT_MASK));
        jMenuItem5.setText("Sair");

        setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
        setTitle("OntoScheduler");
        addWindowListener(new java.awt.event.WindowAdapter() {
            public void windowClosing(java.awt.event.WindowEvent evt) {
                formWindowClosing(evt);
            }
        });

        TabWindow.setName(""); // NOI18N
        TabWindow.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                TabWindowMouseClicked(evt);
            }
        });

        agentPanel.setName(""); // NOI18N

        agentIndividuals.setSelectionMode(javax.swing.ListSelectionModel.SINGLE_SELECTION);
        agentIndividuals.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                agentIndividualsMouseClicked(evt);
            }
        });
        scrollAgent.setViewportView(agentIndividuals);

        agentAdd.setText("Adicionar");
        agentAdd.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                agentAddMouseClicked(evt);
            }
        });

        jScrollPane1.setHorizontalScrollBarPolicy(javax.swing.ScrollPaneConstants.HORIZONTAL_SCROLLBAR_NEVER);

        jLabel1.setText("Nome:");

        agentName.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyReleased(java.awt.event.KeyEvent evt) {
                agentNameKeyReleased(evt);
            }
        });

        jLabel2.setText("Compromissos pessoais:");

        jScrollPane2.setViewportView(agentInternalCommitment);

        jLabel4.setText("Compromissos coletivos:");

        jScrollPane3.setViewportView(agentSocialCommitment);

        javax.swing.GroupLayout agentInnerPanelLayout = new javax.swing.GroupLayout(agentInnerPanel);
        agentInnerPanel.setLayout(agentInnerPanelLayout);
        agentInnerPanelLayout.setHorizontalGroup(
            agentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(agentInnerPanelLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(agentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                    .addGroup(agentInnerPanelLayout.createSequentialGroup()
                        .addGap(12, 12, 12)
                        .addComponent(agentName, javax.swing.GroupLayout.DEFAULT_SIZE, 290, Short.MAX_VALUE))
                    .addComponent(jLabel1)
                    .addComponent(jLabel2)
                    .addComponent(jLabel4)
                    .addGroup(agentInnerPanelLayout.createSequentialGroup()
                        .addGap(12, 12, 12)
                        .addComponent(jScrollPane2))
                    .addGroup(agentInnerPanelLayout.createSequentialGroup()
                        .addGap(12, 12, 12)
                        .addComponent(jScrollPane3)))
                .addContainerGap(46, Short.MAX_VALUE))
        );
        agentInnerPanelLayout.setVerticalGroup(
            agentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(agentInnerPanelLayout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jLabel1)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(agentName, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jLabel2)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, 108, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jLabel4)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jScrollPane3, javax.swing.GroupLayout.PREFERRED_SIZE, 97, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addContainerGap(71, Short.MAX_VALUE))
        );

        agentInnerPanelLayout.linkSize(javax.swing.SwingConstants.VERTICAL, new java.awt.Component[] {jScrollPane2, jScrollPane3});

        jScrollPane1.setViewportView(agentInnerPanel);

        agentSave.setText("Atualizar");
        agentSave.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                agentSaveMouseClicked(evt);
            }
        });

        javax.swing.GroupLayout agentDataPanelLayout = new javax.swing.GroupLayout(agentDataPanel);
        agentDataPanel.setLayout(agentDataPanelLayout);
        agentDataPanelLayout.setHorizontalGroup(
            agentDataPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(agentDataPanelLayout.createSequentialGroup()
                .addGroup(agentDataPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 363, Short.MAX_VALUE)
                    .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, agentDataPanelLayout.createSequentialGroup()
                        .addContainerGap(281, Short.MAX_VALUE)
                        .addComponent(agentSave)))
                .addContainerGap())
        );
        agentDataPanelLayout.setVerticalGroup(
            agentDataPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, agentDataPanelLayout.createSequentialGroup()
                .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 392, Short.MAX_VALUE)
                .addGap(6, 6, 6)
                .addComponent(agentSave))
        );

        javax.swing.GroupLayout agentPanelLayout = new javax.swing.GroupLayout(agentPanel);
        agentPanel.setLayout(agentPanelLayout);
        agentPanelLayout.setHorizontalGroup(
            agentPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(agentPanelLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(agentPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(scrollAgent, javax.swing.GroupLayout.PREFERRED_SIZE, 244, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(agentAdd))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(agentDataPanel, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addContainerGap())
        );
        agentPanelLayout.setVerticalGroup(
            agentPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(agentPanelLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(agentPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(agentDataPanel, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addGroup(agentPanelLayout.createSequentialGroup()
                        .addComponent(scrollAgent, javax.swing.GroupLayout.DEFAULT_SIZE, 392, Short.MAX_VALUE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(agentAdd)))
                .addContainerGap())
        );

        TabWindow.addTab("Pessoas", agentPanel);

        internalCommPanel.setName(""); // NOI18N

        internalCommitmentIndividuals.setSelectionMode(javax.swing.ListSelectionModel.SINGLE_SELECTION);
        internalCommitmentIndividuals.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                internalCommitmentIndividualsMouseClicked(evt);
            }
        });
        scrollAgent1.setViewportView(internalCommitmentIndividuals);

        internalCommitmentAdd.setText("Adicionar");
        internalCommitmentAdd.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                internalCommitmentAddMouseClicked(evt);
            }
        });

        jScrollPane4.setHorizontalScrollBarPolicy(javax.swing.ScrollPaneConstants.HORIZONTAL_SCROLLBAR_NEVER);

        jLabel3.setText("Nome:");

        internalCommitmentName.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyReleased(java.awt.event.KeyEvent evt) {
                internalCommitmentNameKeyReleased(evt);
            }
        });

        jLabel5.setText("Referente à pessoa:");

        jLabel6.setText("Compromete-se a realizar o evento:");

        internalCommitmentAgent.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));

        internalCommitmentActionFO.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));

        jLabel17.setText("Início:");

        jLabel18.setText("Fim:");

        jLabel19.setText("Estado:");

        internalCommitmentStatusButtonGroup.add(internalCommitmentFulfilled);
        internalCommitmentFulfilled.setText("Realizado em:");
        internalCommitmentFulfilled.setBorder(javax.swing.BorderFactory.createEmptyBorder(0, 0, 0, 0));
        internalCommitmentFulfilled.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                internalCommitmentFulfilledMouseClicked(evt);
            }
        });

        internalCommitmentStatus.setForeground(new java.awt.Color(0, 204, 0));
        internalCommitmentStatus.setText("Pendente/Quebrado/Cumprido/Desfeito");

        jLabel21.setText("Início:");

        jLabel22.setText("Fim:");

        internalCommitmentStatusButtonGroup.add(internalCommitmentUnfulfilled);
        internalCommitmentUnfulfilled.setText("Não realizado.");
        internalCommitmentUnfulfilled.setBorder(javax.swing.BorderFactory.createEmptyBorder(0, 0, 0, 0));
        internalCommitmentUnfulfilled.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                internalCommitmentUnfulfilledMouseClicked(evt);
            }
        });

        internalCommitmentPlannedStartCalendar.setMaxSelectableDate(new java.util.Date(253370768494000L));

        internalCommitmentProgrammedButtonGroup.add(internalCommitmentProgramed);
        internalCommitmentProgramed.setText("Compromete-se a realizar em:");
        internalCommitmentProgramed.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                internalCommitmentProgramedMouseClicked(evt);
            }
        });

        internalCommitmentProgrammedButtonGroup.add(internalCommitmentNonProgramed);
        internalCommitmentNonProgramed.setText("Não programado.");
        internalCommitmentNonProgramed.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                internalCommitmentNonProgramedMouseClicked(evt);
            }
        });

        internalCommitmentDismiss.setText("Marcar como desfeito");

        javax.swing.GroupLayout internalCommitmentInnerPanelLayout = new javax.swing.GroupLayout(internalCommitmentInnerPanel);
        internalCommitmentInnerPanel.setLayout(internalCommitmentInnerPanelLayout);
        internalCommitmentInnerPanelLayout.setHorizontalGroup(
            internalCommitmentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(internalCommitmentInnerPanelLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(internalCommitmentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(internalCommitmentInnerPanelLayout.createSequentialGroup()
                        .addGap(12, 12, 12)
                        .addComponent(internalCommitmentStatus))
                    .addComponent(internalCommitmentNonProgramed)
                    .addGroup(internalCommitmentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)
                        .addGroup(javax.swing.GroupLayout.Alignment.LEADING, internalCommitmentInnerPanelLayout.createSequentialGroup()
                            .addGap(12, 12, 12)
                            .addComponent(internalCommitmentActionFO, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                        .addComponent(jLabel3, javax.swing.GroupLayout.Alignment.LEADING)
                        .addComponent(jLabel5, javax.swing.GroupLayout.Alignment.LEADING)
                        .addComponent(jLabel6, javax.swing.GroupLayout.Alignment.LEADING)
                        .addGroup(javax.swing.GroupLayout.Alignment.LEADING, internalCommitmentInnerPanelLayout.createSequentialGroup()
                            .addGap(12, 12, 12)
                            .addGroup(internalCommitmentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)
                                .addComponent(internalCommitmentAgent, javax.swing.GroupLayout.Alignment.LEADING, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                                .addComponent(internalCommitmentName, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, 290, Short.MAX_VALUE))))
                    .addComponent(jLabel19)
                    .addGroup(internalCommitmentInnerPanelLayout.createSequentialGroup()
                        .addGap(21, 21, 21)
                        .addGroup(internalCommitmentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                            .addGroup(internalCommitmentInnerPanelLayout.createSequentialGroup()
                                .addComponent(jLabel18)
                                .addGap(22, 22, 22)
                                .addComponent(internalCommitmentPlannedEndCalendar, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                            .addGroup(internalCommitmentInnerPanelLayout.createSequentialGroup()
                                .addComponent(jLabel17)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(internalCommitmentPlannedStartCalendar, javax.swing.GroupLayout.PREFERRED_SIZE, 122, javax.swing.GroupLayout.PREFERRED_SIZE))))
                    .addComponent(internalCommitmentProgramed)
                    .addGroup(internalCommitmentInnerPanelLayout.createSequentialGroup()
                        .addGap(12, 12, 12)
                        .addGroup(internalCommitmentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addGroup(internalCommitmentInnerPanelLayout.createSequentialGroup()
                                .addGap(17, 17, 17)
                                .addGroup(internalCommitmentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)
                                    .addGroup(internalCommitmentInnerPanelLayout.createSequentialGroup()
                                        .addComponent(jLabel22)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                                        .addComponent(internalCommitmentActualEndCalendar, javax.swing.GroupLayout.PREFERRED_SIZE, 95, javax.swing.GroupLayout.PREFERRED_SIZE))
                                    .addGroup(internalCommitmentInnerPanelLayout.createSequentialGroup()
                                        .addComponent(jLabel21)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(internalCommitmentActualStartCalendar, javax.swing.GroupLayout.PREFERRED_SIZE, 122, javax.swing.GroupLayout.PREFERRED_SIZE))))
                            .addComponent(internalCommitmentFulfilled)
                            .addComponent(internalCommitmentDismiss)
                            .addComponent(internalCommitmentUnfulfilled))))
                .addContainerGap(71, Short.MAX_VALUE))
        );

        internalCommitmentInnerPanelLayout.linkSize(javax.swing.SwingConstants.HORIZONTAL, new java.awt.Component[] {internalCommitmentActualEndCalendar, internalCommitmentActualStartCalendar});

        internalCommitmentInnerPanelLayout.setVerticalGroup(
            internalCommitmentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(internalCommitmentInnerPanelLayout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jLabel3)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(internalCommitmentName, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jLabel5)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(internalCommitmentAgent, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jLabel6)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(internalCommitmentActionFO, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addGap(6, 6, 6)
                .addComponent(internalCommitmentNonProgramed)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(internalCommitmentProgramed)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(internalCommitmentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jLabel17)
                    .addComponent(internalCommitmentPlannedStartCalendar, javax.swing.GroupLayout.PREFERRED_SIZE, 19, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(internalCommitmentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(internalCommitmentInnerPanelLayout.createSequentialGroup()
                        .addComponent(jLabel18)
                        .addGap(11, 11, 11)
                        .addComponent(jLabel19))
                    .addComponent(internalCommitmentPlannedEndCalendar, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(internalCommitmentStatus)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(internalCommitmentDismiss)
                .addGap(4, 4, 4)
                .addComponent(internalCommitmentUnfulfilled)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(internalCommitmentFulfilled)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(internalCommitmentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jLabel21)
                    .addComponent(internalCommitmentActualStartCalendar, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(internalCommitmentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(internalCommitmentActualEndCalendar, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jLabel22))
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );

        jScrollPane4.setViewportView(internalCommitmentInnerPanel);

        internalCommitmentSave.setText("Atualizar");
        internalCommitmentSave.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                internalCommitmentSaveMouseClicked(evt);
            }
        });

        javax.swing.GroupLayout internalCommitmentDataPanelLayout = new javax.swing.GroupLayout(internalCommitmentDataPanel);
        internalCommitmentDataPanel.setLayout(internalCommitmentDataPanelLayout);
        internalCommitmentDataPanelLayout.setHorizontalGroup(
            internalCommitmentDataPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(internalCommitmentDataPanelLayout.createSequentialGroup()
                .addGroup(internalCommitmentDataPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jScrollPane4, javax.swing.GroupLayout.DEFAULT_SIZE, 363, Short.MAX_VALUE)
                    .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, internalCommitmentDataPanelLayout.createSequentialGroup()
                        .addContainerGap(281, Short.MAX_VALUE)
                        .addComponent(internalCommitmentSave)))
                .addContainerGap())
        );
        internalCommitmentDataPanelLayout.setVerticalGroup(
            internalCommitmentDataPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, internalCommitmentDataPanelLayout.createSequentialGroup()
                .addComponent(jScrollPane4, javax.swing.GroupLayout.DEFAULT_SIZE, 392, Short.MAX_VALUE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(internalCommitmentSave))
        );

        javax.swing.GroupLayout internalCommPanelLayout = new javax.swing.GroupLayout(internalCommPanel);
        internalCommPanel.setLayout(internalCommPanelLayout);
        internalCommPanelLayout.setHorizontalGroup(
            internalCommPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(internalCommPanelLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(internalCommPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(scrollAgent1, javax.swing.GroupLayout.PREFERRED_SIZE, 244, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(internalCommitmentAdd))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(internalCommitmentDataPanel, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addContainerGap())
        );
        internalCommPanelLayout.setVerticalGroup(
            internalCommPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, internalCommPanelLayout.createSequentialGroup()
                .addGroup(internalCommPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                    .addGroup(javax.swing.GroupLayout.Alignment.LEADING, internalCommPanelLayout.createSequentialGroup()
                        .addContainerGap()
                        .addComponent(internalCommitmentDataPanel, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                    .addGroup(internalCommPanelLayout.createSequentialGroup()
                        .addGap(12, 12, 12)
                        .addComponent(scrollAgent1, javax.swing.GroupLayout.DEFAULT_SIZE, 392, Short.MAX_VALUE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(internalCommitmentAdd)))
                .addContainerGap())
        );

        TabWindow.addTab("Compromissos pessoais", internalCommPanel);

        socialCommPanel.setName(""); // NOI18N

        socialCommitmentIndividuals.setSelectionMode(javax.swing.ListSelectionModel.SINGLE_SELECTION);
        socialCommitmentIndividuals.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                socialCommitmentIndividualsMouseClicked(evt);
            }
        });
        scrollAgent2.setViewportView(socialCommitmentIndividuals);

        socialCommitmentAdd.setText("Adicionar");
        socialCommitmentAdd.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                socialCommitmentAddMouseClicked(evt);
            }
        });

        jLabel7.setText("Nome:");

        socialCommitmentName.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyReleased(java.awt.event.KeyEvent evt) {
                socialCommitmentNameKeyReleased(evt);
            }
        });

        jLabel8.setText("Referente às pessoas:");

        jLabel9.setText("Compromete-se a realizar o evento:");

        socialCommitmentActionFO.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));

        jLabel24.setText("Início:");

        jLabel25.setText("Fim:");

        jLabel26.setText("Estado:");

        socialCommitmentStatusButtonGroup.add(socialCommitmentFulfilled);
        socialCommitmentFulfilled.setText("Realizado em:");
        socialCommitmentFulfilled.setBorder(javax.swing.BorderFactory.createEmptyBorder(0, 0, 0, 0));
        socialCommitmentFulfilled.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                socialCommitmentFulfilledMouseClicked(evt);
            }
        });

        socialCommitmentStatus.setForeground(new java.awt.Color(0, 204, 0));
        socialCommitmentStatus.setText("Pendente/Quebrado/Concluído/Desfeito");

        jLabel28.setText("Início:");

        jLabel29.setText("Fim:");

        socialCommitmentStatusButtonGroup.add(socialCommitmentUnfulfilled);
        socialCommitmentUnfulfilled.setText("Não realizado.");
        socialCommitmentUnfulfilled.setBorder(javax.swing.BorderFactory.createEmptyBorder(0, 0, 0, 0));
        socialCommitmentUnfulfilled.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                socialCommitmentUnfulfilledMouseClicked(evt);
            }
        });

        socialCommitmentAgents.setSelectionMode(javax.swing.ListSelectionModel.SINGLE_SELECTION);
        jScrollPane6.setViewportView(socialCommitmentAgents);

        socialCommitmentAgentCombo.setMaximumSize(new java.awt.Dimension(31, 23));

        socialCommitmentAgentAdd.setText("+");
        socialCommitmentAgentAdd.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                socialCommitmentAgentAddMouseClicked(evt);
            }
        });

        socialCommitmentAgentRemove.setText("-");
        socialCommitmentAgentRemove.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                socialCommitmentAgentRemoveMouseClicked(evt);
            }
        });

        socialCommitmentProgrammedButtonGroup.add(socialCommitmentNonProgramed);
        socialCommitmentNonProgramed.setText("Não programado.");
        socialCommitmentNonProgramed.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                socialCommitmentNonProgramedMouseClicked(evt);
            }
        });

        socialCommitmentProgrammedButtonGroup.add(socialCommitmentProgramed);
        socialCommitmentProgramed.setText("Compromete-se a realizar em:");
        socialCommitmentProgramed.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                socialCommitmentProgramedMouseClicked(evt);
            }
        });

        jLabel15.setText("Responsável:");

        socialCommitmentResponsable.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));

        socialCommitmentDismiss.setText("Marcar como desfeito");

        javax.swing.GroupLayout socialCommitmentInnerPanelLayout = new javax.swing.GroupLayout(socialCommitmentInnerPanel);
        socialCommitmentInnerPanel.setLayout(socialCommitmentInnerPanelLayout);
        socialCommitmentInnerPanelLayout.setHorizontalGroup(
            socialCommitmentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(socialCommitmentInnerPanelLayout.createSequentialGroup()
                .addGroup(socialCommitmentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(socialCommitmentInnerPanelLayout.createSequentialGroup()
                        .addContainerGap()
                        .addComponent(socialCommitmentNonProgramed))
                    .addGroup(socialCommitmentInnerPanelLayout.createSequentialGroup()
                        .addGap(24, 24, 24)
                        .addGroup(socialCommitmentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(jLabel24)
                            .addComponent(jLabel25))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addGroup(socialCommitmentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                            .addComponent(socialCommitmentPlannedEndCalendar, javax.swing.GroupLayout.DEFAULT_SIZE, 122, Short.MAX_VALUE)
                            .addComponent(socialCommitmentPlannedStartCalendar, javax.swing.GroupLayout.DEFAULT_SIZE, 122, Short.MAX_VALUE)))
                    .addGroup(socialCommitmentInnerPanelLayout.createSequentialGroup()
                        .addContainerGap()
                        .addComponent(socialCommitmentProgramed))
                    .addGroup(socialCommitmentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)
                        .addGroup(javax.swing.GroupLayout.Alignment.LEADING, socialCommitmentInnerPanelLayout.createSequentialGroup()
                            .addGap(36, 36, 36)
                            .addComponent(socialCommitmentResponsable, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                        .addGroup(javax.swing.GroupLayout.Alignment.LEADING, socialCommitmentInnerPanelLayout.createSequentialGroup()
                            .addGap(24, 24, 24)
                            .addComponent(jScrollPane6))
                        .addGroup(javax.swing.GroupLayout.Alignment.LEADING, socialCommitmentInnerPanelLayout.createSequentialGroup()
                            .addContainerGap()
                            .addGroup(socialCommitmentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                .addComponent(jLabel9)
                                .addComponent(jLabel7)
                                .addComponent(jLabel8)
                                .addGroup(socialCommitmentInnerPanelLayout.createSequentialGroup()
                                    .addGap(12, 12, 12)
                                    .addComponent(jLabel15))
                                .addGroup(socialCommitmentInnerPanelLayout.createSequentialGroup()
                                    .addGap(12, 12, 12)
                                    .addGroup(socialCommitmentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                        .addComponent(socialCommitmentName, javax.swing.GroupLayout.PREFERRED_SIZE, 290, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, socialCommitmentInnerPanelLayout.createSequentialGroup()
                                            .addComponent(socialCommitmentAgentCombo, javax.swing.GroupLayout.PREFERRED_SIZE, 195, javax.swing.GroupLayout.PREFERRED_SIZE)
                                            .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                            .addComponent(socialCommitmentAgentAdd)
                                            .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                            .addComponent(socialCommitmentAgentRemove))))
                                .addGroup(socialCommitmentInnerPanelLayout.createSequentialGroup()
                                    .addGap(12, 12, 12)
                                    .addComponent(socialCommitmentActionFO, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)))))
                    .addGroup(socialCommitmentInnerPanelLayout.createSequentialGroup()
                        .addContainerGap()
                        .addGroup(socialCommitmentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(jLabel26)
                            .addGroup(socialCommitmentInnerPanelLayout.createSequentialGroup()
                                .addGap(12, 12, 12)
                                .addGroup(socialCommitmentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                    .addComponent(socialCommitmentUnfulfilled)
                                    .addComponent(socialCommitmentFulfilled)
                                    .addGroup(socialCommitmentInnerPanelLayout.createSequentialGroup()
                                        .addGap(17, 17, 17)
                                        .addGroup(socialCommitmentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                            .addComponent(jLabel29)
                                            .addComponent(jLabel28))
                                        .addGap(8, 8, 8)
                                        .addGroup(socialCommitmentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                            .addComponent(socialCommitmentActualStartCalendar, javax.swing.GroupLayout.PREFERRED_SIZE, 122, javax.swing.GroupLayout.PREFERRED_SIZE)
                                            .addComponent(socialCommitmentActualEndCalendar, javax.swing.GroupLayout.PREFERRED_SIZE, 122, javax.swing.GroupLayout.PREFERRED_SIZE)))))
                            .addGroup(socialCommitmentInnerPanelLayout.createSequentialGroup()
                                .addGap(12, 12, 12)
                                .addGroup(socialCommitmentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                    .addComponent(socialCommitmentDismiss)
                                    .addComponent(socialCommitmentStatus))))))
                .addContainerGap(31, Short.MAX_VALUE))
        );
        socialCommitmentInnerPanelLayout.setVerticalGroup(
            socialCommitmentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(socialCommitmentInnerPanelLayout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jLabel7)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(socialCommitmentName, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jLabel8)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(socialCommitmentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(socialCommitmentAgentRemove)
                    .addComponent(socialCommitmentAgentAdd)
                    .addComponent(socialCommitmentAgentCombo, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jScrollPane6, javax.swing.GroupLayout.PREFERRED_SIZE, 83, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jLabel15)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(socialCommitmentResponsable, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jLabel9)
                .addGap(4, 4, 4)
                .addComponent(socialCommitmentActionFO, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addComponent(socialCommitmentNonProgramed)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(socialCommitmentProgramed)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(socialCommitmentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jLabel24)
                    .addComponent(socialCommitmentPlannedStartCalendar, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(socialCommitmentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jLabel25)
                    .addComponent(socialCommitmentPlannedEndCalendar, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addComponent(jLabel26)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(socialCommitmentStatus)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(socialCommitmentDismiss)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addComponent(socialCommitmentUnfulfilled)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(socialCommitmentFulfilled)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(socialCommitmentInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)
                    .addGroup(socialCommitmentInnerPanelLayout.createSequentialGroup()
                        .addComponent(jLabel28)
                        .addGap(11, 11, 11)
                        .addComponent(jLabel29))
                    .addGroup(socialCommitmentInnerPanelLayout.createSequentialGroup()
                        .addComponent(socialCommitmentActualStartCalendar, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                        .addComponent(socialCommitmentActualEndCalendar, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)))
                .addGap(48, 48, 48))
        );

        jScrollPane5.setViewportView(socialCommitmentInnerPanel);

        socialCommitmentSave.setText("Atualizar");
        socialCommitmentSave.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                socialCommitmentSaveMouseClicked(evt);
            }
        });

        javax.swing.GroupLayout socialCommitmentDataPanelLayout = new javax.swing.GroupLayout(socialCommitmentDataPanel);
        socialCommitmentDataPanel.setLayout(socialCommitmentDataPanelLayout);
        socialCommitmentDataPanelLayout.setHorizontalGroup(
            socialCommitmentDataPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(socialCommitmentDataPanelLayout.createSequentialGroup()
                .addGroup(socialCommitmentDataPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jScrollPane5, javax.swing.GroupLayout.DEFAULT_SIZE, 363, Short.MAX_VALUE)
                    .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, socialCommitmentDataPanelLayout.createSequentialGroup()
                        .addContainerGap(281, Short.MAX_VALUE)
                        .addComponent(socialCommitmentSave)))
                .addContainerGap())
        );
        socialCommitmentDataPanelLayout.setVerticalGroup(
            socialCommitmentDataPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, socialCommitmentDataPanelLayout.createSequentialGroup()
                .addComponent(jScrollPane5, javax.swing.GroupLayout.DEFAULT_SIZE, 392, Short.MAX_VALUE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(socialCommitmentSave))
        );

        javax.swing.GroupLayout socialCommPanelLayout = new javax.swing.GroupLayout(socialCommPanel);
        socialCommPanel.setLayout(socialCommPanelLayout);
        socialCommPanelLayout.setHorizontalGroup(
            socialCommPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(socialCommPanelLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(socialCommPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(scrollAgent2, javax.swing.GroupLayout.PREFERRED_SIZE, 244, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(socialCommitmentAdd))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(socialCommitmentDataPanel, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addContainerGap())
        );
        socialCommPanelLayout.setVerticalGroup(
            socialCommPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, socialCommPanelLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(socialCommPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                    .addComponent(socialCommitmentDataPanel, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addGroup(socialCommPanelLayout.createSequentialGroup()
                        .addComponent(scrollAgent2, javax.swing.GroupLayout.DEFAULT_SIZE, 392, Short.MAX_VALUE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(socialCommitmentAdd)))
                .addContainerGap())
        );

        TabWindow.addTab("Compromissos sociais", socialCommPanel);

        actionFOPanel.setName(""); // NOI18N

        actionFOIndividuals.setSelectionMode(javax.swing.ListSelectionModel.SINGLE_SELECTION);
        actionFOIndividuals.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                actionFOIndividualsMouseClicked(evt);
            }
        });
        scrollAgent3.setViewportView(actionFOIndividuals);

        actionFOAdd.setText("Adicionar");
        actionFOAdd.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                actionFOAddMouseClicked(evt);
            }
        });

        jScrollPane10.setHorizontalScrollBarPolicy(javax.swing.ScrollPaneConstants.HORIZONTAL_SCROLLBAR_NEVER);

        jLabel10.setText("Nome:");

        actionFOName.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyReleased(java.awt.event.KeyEvent evt) {
                actionFONameKeyReleased(evt);
            }
        });

        jLabel11.setText("Compromissos pessoais relacionados:");

        actionFOInternalCommitment.setSelectionMode(javax.swing.ListSelectionModel.SINGLE_SELECTION);
        jScrollPane7.setViewportView(actionFOInternalCommitment);

        jLabel12.setText("Compromissos sociais relacionados:");

        actionFOSocialCommitment.setSelectionMode(javax.swing.ListSelectionModel.SINGLE_SELECTION);
        jScrollPane8.setViewportView(actionFOSocialCommitment);

        jLabel30.setText("Categoria:");

        actionFOActionHO.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));

        jLabel16.setText("Probabilidades:");

        jLabel20.setText("Ser concluído:");

        jLabel23.setText("Ser desfeito:");

        jLabel27.setText("Ser quebrado:");

        jProgressBar1.setValue(50);
        jProgressBar1.setStringPainted(true);

        jProgressBar2.setValue(10);
        jProgressBar2.setStringPainted(true);

        jProgressBar3.setValue(40);
        jProgressBar3.setStringPainted(true);

        javax.swing.GroupLayout actionFOInnerPannelLayout = new javax.swing.GroupLayout(actionFOInnerPannel);
        actionFOInnerPannel.setLayout(actionFOInnerPannelLayout);
        actionFOInnerPannelLayout.setHorizontalGroup(
            actionFOInnerPannelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(actionFOInnerPannelLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(actionFOInnerPannelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(actionFOInnerPannelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                        .addGroup(actionFOInnerPannelLayout.createSequentialGroup()
                            .addGap(12, 12, 12)
                            .addComponent(jScrollPane8))
                        .addGroup(actionFOInnerPannelLayout.createSequentialGroup()
                            .addGap(12, 12, 12)
                            .addComponent(actionFOActionHO, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                        .addGroup(actionFOInnerPannelLayout.createSequentialGroup()
                            .addGap(12, 12, 12)
                            .addComponent(actionFOName, javax.swing.GroupLayout.DEFAULT_SIZE, 290, Short.MAX_VALUE))
                        .addComponent(jLabel10)
                        .addComponent(jLabel30)
                        .addComponent(jLabel11)
                        .addComponent(jLabel12)
                        .addGroup(actionFOInnerPannelLayout.createSequentialGroup()
                            .addGap(12, 12, 12)
                            .addComponent(jScrollPane7)))
                    .addComponent(jLabel16)
                    .addGroup(actionFOInnerPannelLayout.createSequentialGroup()
                        .addGap(12, 12, 12)
                        .addGroup(actionFOInnerPannelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                            .addComponent(jLabel27)
                            .addGroup(actionFOInnerPannelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                .addComponent(jLabel23)
                                .addComponent(jLabel20)))
                        .addGap(12, 12, 12)
                        .addGroup(actionFOInnerPannelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(jProgressBar1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jProgressBar2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jProgressBar3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))))
                .addContainerGap(46, Short.MAX_VALUE))
        );

        actionFOInnerPannelLayout.linkSize(javax.swing.SwingConstants.HORIZONTAL, new java.awt.Component[] {actionFOActionHO, actionFOName, jScrollPane8});

        actionFOInnerPannelLayout.setVerticalGroup(
            actionFOInnerPannelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(actionFOInnerPannelLayout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jLabel10)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(actionFOName, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jLabel30)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(actionFOActionHO, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jLabel11)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jScrollPane7, javax.swing.GroupLayout.PREFERRED_SIZE, 77, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jLabel12)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jScrollPane8, javax.swing.GroupLayout.PREFERRED_SIZE, 25, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jLabel16)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(actionFOInnerPannelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jProgressBar1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jLabel20))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(actionFOInnerPannelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jProgressBar2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jLabel23))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(actionFOInnerPannelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jProgressBar3, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jLabel27))
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );

        actionFOInnerPannelLayout.linkSize(javax.swing.SwingConstants.VERTICAL, new java.awt.Component[] {jScrollPane7, jScrollPane8});

        jScrollPane10.setViewportView(actionFOInnerPannel);

        actionFOSave.setText("Atualizar");
        actionFOSave.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                actionFOSaveMouseClicked(evt);
            }
        });

        javax.swing.GroupLayout actionFODataPanelLayout = new javax.swing.GroupLayout(actionFODataPanel);
        actionFODataPanel.setLayout(actionFODataPanelLayout);
        actionFODataPanelLayout.setHorizontalGroup(
            actionFODataPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(actionFODataPanelLayout.createSequentialGroup()
                .addGroup(actionFODataPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jScrollPane10, javax.swing.GroupLayout.DEFAULT_SIZE, 363, Short.MAX_VALUE)
                    .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, actionFODataPanelLayout.createSequentialGroup()
                        .addContainerGap(281, Short.MAX_VALUE)
                        .addComponent(actionFOSave)))
                .addContainerGap())
        );
        actionFODataPanelLayout.setVerticalGroup(
            actionFODataPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, actionFODataPanelLayout.createSequentialGroup()
                .addComponent(jScrollPane10, javax.swing.GroupLayout.DEFAULT_SIZE, 392, Short.MAX_VALUE)
                .addGap(6, 6, 6)
                .addComponent(actionFOSave))
        );

        javax.swing.GroupLayout actionFOPanelLayout = new javax.swing.GroupLayout(actionFOPanel);
        actionFOPanel.setLayout(actionFOPanelLayout);
        actionFOPanelLayout.setHorizontalGroup(
            actionFOPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(actionFOPanelLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(actionFOPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(scrollAgent3, javax.swing.GroupLayout.PREFERRED_SIZE, 244, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(actionFOAdd))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(actionFODataPanel, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addContainerGap())
        );
        actionFOPanelLayout.setVerticalGroup(
            actionFOPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(actionFOPanelLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(actionFOPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(actionFODataPanel, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, actionFOPanelLayout.createSequentialGroup()
                        .addComponent(scrollAgent3, javax.swing.GroupLayout.DEFAULT_SIZE, 392, Short.MAX_VALUE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(actionFOAdd)))
                .addContainerGap())
        );

        TabWindow.addTab("Eventos", actionFOPanel);

        actionHOPanel.setName(""); // NOI18N

        actionHOIndividuals.setSelectionMode(javax.swing.ListSelectionModel.SINGLE_SELECTION);
        actionHOIndividuals.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                actionHOIndividualsMouseClicked(evt);
            }
        });
        scrollAgent4.setViewportView(actionHOIndividuals);

        actionHOAdd.setText("Adicionar");
        actionHOAdd.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                actionHOAddMouseClicked(evt);
            }
        });

        jScrollPane13.setHorizontalScrollBarPolicy(javax.swing.ScrollPaneConstants.HORIZONTAL_SCROLLBAR_NEVER);

        jLabel13.setText("Nome:");

        actionHOName.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyReleased(java.awt.event.KeyEvent evt) {
                actionHONameKeyReleased(evt);
            }
        });

        jLabel14.setText("Eventos desta categoria:");

        actionHOActionFO.setSelectionMode(javax.swing.ListSelectionModel.SINGLE_SELECTION);
        jScrollPane14.setViewportView(actionHOActionFO);

        javax.swing.GroupLayout actionHOInnerPanelLayout = new javax.swing.GroupLayout(actionHOInnerPanel);
        actionHOInnerPanel.setLayout(actionHOInnerPanelLayout);
        actionHOInnerPanelLayout.setHorizontalGroup(
            actionHOInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(actionHOInnerPanelLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(actionHOInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                    .addGroup(actionHOInnerPanelLayout.createSequentialGroup()
                        .addGap(12, 12, 12)
                        .addComponent(actionHOName, javax.swing.GroupLayout.DEFAULT_SIZE, 290, Short.MAX_VALUE))
                    .addComponent(jLabel13)
                    .addComponent(jLabel14)
                    .addGroup(actionHOInnerPanelLayout.createSequentialGroup()
                        .addGap(12, 12, 12)
                        .addComponent(jScrollPane14)))
                .addContainerGap(46, Short.MAX_VALUE))
        );
        actionHOInnerPanelLayout.setVerticalGroup(
            actionHOInnerPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(actionHOInnerPanelLayout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jLabel13)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(actionHOName, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jLabel14)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jScrollPane14, javax.swing.GroupLayout.PREFERRED_SIZE, 108, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addContainerGap(205, Short.MAX_VALUE))
        );

        jScrollPane13.setViewportView(actionHOInnerPanel);

        actionHOSave.setText("Atualizar");
        actionHOSave.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                actionHOSaveMouseClicked(evt);
            }
        });

        javax.swing.GroupLayout actionHODataPanelLayout = new javax.swing.GroupLayout(actionHODataPanel);
        actionHODataPanel.setLayout(actionHODataPanelLayout);
        actionHODataPanelLayout.setHorizontalGroup(
            actionHODataPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(actionHODataPanelLayout.createSequentialGroup()
                .addGroup(actionHODataPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jScrollPane13, javax.swing.GroupLayout.DEFAULT_SIZE, 363, Short.MAX_VALUE)
                    .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, actionHODataPanelLayout.createSequentialGroup()
                        .addContainerGap(281, Short.MAX_VALUE)
                        .addComponent(actionHOSave)))
                .addContainerGap())
        );
        actionHODataPanelLayout.setVerticalGroup(
            actionHODataPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, actionHODataPanelLayout.createSequentialGroup()
                .addComponent(jScrollPane13, javax.swing.GroupLayout.DEFAULT_SIZE, 392, Short.MAX_VALUE)
                .addGap(6, 6, 6)
                .addComponent(actionHOSave))
        );

        javax.swing.GroupLayout actionHOPanelLayout = new javax.swing.GroupLayout(actionHOPanel);
        actionHOPanel.setLayout(actionHOPanelLayout);
        actionHOPanelLayout.setHorizontalGroup(
            actionHOPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(actionHOPanelLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(actionHOPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(scrollAgent4, javax.swing.GroupLayout.PREFERRED_SIZE, 244, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(actionHOAdd))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(actionHODataPanel, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addContainerGap())
        );
        actionHOPanelLayout.setVerticalGroup(
            actionHOPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(actionHOPanelLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(actionHOPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, actionHOPanelLayout.createSequentialGroup()
                        .addComponent(scrollAgent4, javax.swing.GroupLayout.DEFAULT_SIZE, 392, Short.MAX_VALUE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(actionHOAdd))
                    .addComponent(actionHODataPanel, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addContainerGap())
        );

        TabWindow.addTab("Categorias de evento", actionHOPanel);

        jMenu1.setText("Arquivo");

        fileNew.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_N, java.awt.event.InputEvent.CTRL_MASK));
        fileNew.setText("Novo");
        fileNew.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                fileNewActionPerformed(evt);
            }
        });
        jMenu1.add(fileNew);
        jMenu1.add(jSeparator5);

        fileOpen.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_O, java.awt.event.InputEvent.CTRL_MASK));
        fileOpen.setText("Abrir...");
        fileOpen.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                fileOpenActionPerformed(evt);
            }
        });
        jMenu1.add(fileOpen);
        jMenu1.add(jSeparator3);

        fileSave.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_S, java.awt.event.InputEvent.CTRL_MASK));
        fileSave.setText("Salvar");
        fileSave.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                fileSaveActionPerformed(evt);
            }
        });
        jMenu1.add(fileSave);

        fileSaveAs.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_S, java.awt.event.InputEvent.SHIFT_MASK | java.awt.event.InputEvent.CTRL_MASK));
        fileSaveAs.setText("Salvar Como...");
        fileSaveAs.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                fileSaveAsActionPerformed(evt);
            }
        });
        jMenu1.add(fileSaveAs);
        jMenu1.add(jSeparator4);

        fileCloseFile.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_W, java.awt.event.InputEvent.CTRL_MASK));
        fileCloseFile.setText("Fechar arquivo");
        fileCloseFile.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                fileCloseFileActionPerformed(evt);
            }
        });
        jMenu1.add(fileCloseFile);

        fileExit.setAccelerator(javax.swing.KeyStroke.getKeyStroke(java.awt.event.KeyEvent.VK_F4, java.awt.event.InputEvent.ALT_MASK));
        fileExit.setText("Sair");
        fileExit.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                fileExitActionPerformed(evt);
            }
        });
        jMenu1.add(fileExit);

        jMenuBar1.add(jMenu1);

        setJMenuBar(jMenuBar1);

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
        getContentPane().setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addComponent(TabWindow, javax.swing.GroupLayout.PREFERRED_SIZE, 654, javax.swing.GroupLayout.PREFERRED_SIZE)
        );
        layout.setVerticalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addComponent(TabWindow, javax.swing.GroupLayout.DEFAULT_SIZE, 472, Short.MAX_VALUE)
        );

        TabWindow.getAccessibleContext().setAccessibleName("Compromissos pessoais");
        TabWindow.getAccessibleContext().setAccessibleDescription("Compromissos");

        pack();
    }// </editor-fold>//GEN-END:initComponents

    private void socialCommitmentFulfilledMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_socialCommitmentFulfilledMouseClicked
        socialCommitmentActualStartCalendar.setEnabled(true);
        socialCommitmentActualEndCalendar.setEnabled(true);
        socialCommitmentUnfulfilled.setEnabled(true);
    }//GEN-LAST:event_socialCommitmentFulfilledMouseClicked

    private void socialCommitmentUnfulfilledMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_socialCommitmentUnfulfilledMouseClicked
        socialCommitmentActualStartCalendar.setEnabled(false);
        socialCommitmentActualEndCalendar.setEnabled(false);
        socialCommitmentStatusButtonGroup.setSelected(socialCommitmentUnfulfilled.getModel(), true);
    }//GEN-LAST:event_socialCommitmentUnfulfilledMouseClicked

    private void internalCommitmentUnfulfilledMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_internalCommitmentUnfulfilledMouseClicked
        internalCommitmentActualStartCalendar.setEnabled(false);
        internalCommitmentActualEndCalendar.setEnabled(false);
        internalCommitmentStatusButtonGroup.setSelected(internalCommitmentUnfulfilled.getModel(), true);
    }//GEN-LAST:event_internalCommitmentUnfulfilledMouseClicked

    private void internalCommitmentFulfilledMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_internalCommitmentFulfilledMouseClicked
        internalCommitmentActualStartCalendar.setEnabled(true);
        internalCommitmentActualEndCalendar.setEnabled(true);
        internalCommitmentUnfulfilled.setEnabled(true);
    }//GEN-LAST:event_internalCommitmentFulfilledMouseClicked

    private void socialCommitmentAgentRemoveMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_socialCommitmentAgentRemoveMouseClicked
        DefaultListModel model = (DefaultListModel) socialCommitmentAgents.getModel();
        model.removeElement(socialCommitmentAgentCombo.getSelectedItem());
    }//GEN-LAST:event_socialCommitmentAgentRemoveMouseClicked

    private void socialCommitmentAgentAddMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_socialCommitmentAgentAddMouseClicked
        Object selected = socialCommitmentAgentCombo.getSelectedItem();
        DefaultListModel model = (DefaultListModel) socialCommitmentAgents.getModel();
        if (!model.contains(selected)) {
            model.addElement(selected);
        }
    }//GEN-LAST:event_socialCommitmentAgentAddMouseClicked

    private void internalCommitmentSaveMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_internalCommitmentSaveMouseClicked
        saveName(internalCommitmentIndividuals, internalCommitmentName, jena.internalCommitment);
        saveComboBox(internalCommitmentIndividuals, internalCommitmentAgent, agentIndividuals, jena.internalCommitment, "inherence");
        saveComboBox(internalCommitmentIndividuals, internalCommitmentActionFO, actionFOIndividuals, jena.internalCommitment, "basedOn");
        saveDate(internalCommitmentIndividuals, jena.internalCommitment, internalCommitmentPlannedStartCalendar, internalCommitmentPlannedEndCalendar, "inv-propositionalContentOf");
        saveDate(internalCommitmentIndividuals, jena.internalCommitment, internalCommitmentActualStartCalendar, internalCommitmentActualEndCalendar, "inv-causedBy");
    }//GEN-LAST:event_internalCommitmentSaveMouseClicked

    private void socialCommitmentSaveMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_socialCommitmentSaveMouseClicked
        saveName(socialCommitmentIndividuals, socialCommitmentName, jena.socialCommitment);
        saveList(socialCommitmentIndividuals, socialCommitmentAgents, agentIndividuals, jena.socialCommitment, "externalDependency");
        saveComboBox(socialCommitmentIndividuals, socialCommitmentActionFO, actionFOIndividuals, jena.socialCommitment, "basedOn");
        saveDate(socialCommitmentIndividuals, jena.socialCommitment, socialCommitmentPlannedStartCalendar, socialCommitmentPlannedEndCalendar, "inv-propositionalContentOf");
        saveDate(socialCommitmentIndividuals, jena.socialCommitment, socialCommitmentActualStartCalendar, socialCommitmentActualEndCalendar, "inv-causedBy");
    }//GEN-LAST:event_socialCommitmentSaveMouseClicked

    private void actionFOSaveMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_actionFOSaveMouseClicked
        saveName(actionFOIndividuals, actionFOName, jena.actionUniversalFO);
        saveComboBox(actionFOIndividuals, actionFOActionHO, actionHOIndividuals, jena.actionUniversalFO, "instanceOf");
    }//GEN-LAST:event_actionFOSaveMouseClicked

    private void actionHOSaveMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_actionHOSaveMouseClicked
        saveName(actionHOIndividuals, actionHOName, jena.actionUniversalHO);
    }//GEN-LAST:event_actionHOSaveMouseClicked

    private void agentSaveMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_agentSaveMouseClicked
        saveName(agentIndividuals, agentName, jena.agent);
    }//GEN-LAST:event_agentSaveMouseClicked

    private void actionHOIndividualsMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_actionHOIndividualsMouseClicked
        int selectedIndex = actionHOIndividuals.getSelectedIndex();
        if (selectedIndex == -1) {
            actionHODataPanel.setVisible(false);
            return;
        }
        
        actionHODataPanel.setVisible(true);

        DefaultListModelWithIndividual model = (DefaultListModelWithIndividual) actionHOIndividuals.getModel();
        actionHOName.setText((String) actionHOIndividuals.getSelectedValue());

        Individual ind = model.getIndividual(selectedIndex);
        loadPropertyList(actionHOActionFO, jena.actionUniversalHO, ind, "inv-instanceOf");
    }//GEN-LAST:event_actionHOIndividualsMouseClicked

    private void actionFOIndividualsMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_actionFOIndividualsMouseClicked
        int selectedIndex = actionFOIndividuals.getSelectedIndex();
        if (selectedIndex == -1) {
            actionFODataPanel.setVisible(false);
            return;
        }
        
        actionFODataPanel.setVisible(true);

        DefaultListModelWithIndividual model = (DefaultListModelWithIndividual) actionFOIndividuals.getModel();
        actionFOName.setText((String) actionFOIndividuals.getSelectedValue());

        Individual ind = model.getIndividual(selectedIndex);

        DefaultListModel m1 = (DefaultListModel) actionFOInternalCommitment.getModel();
        m1.removeAllElements();
        DefaultListModel m2 = (DefaultListModel) actionFOSocialCommitment.getModel();
        m2.removeAllElements();

        Iterator iter = jena.actionUniversalFO.getPropertyValues("inv-basedOn", ind);
        while (iter.hasNext()) {
            Resource r = (Resource) iter.next();
            OntModel ontmodel = (OntModel) r.getModel();
            Individual i = ontmodel.getIndividual(r.getURI());
            if (i.getRDFType() == i.getModel().getResource(jena.ns + "InternalCommitment")) {
                m1.addElement(i.getLabel(null));
            } else {
                m2.addElement(i.getLabel(null));
            }
        }

        loadComboBox(actionFOActionHO, jena.actionUniversalFO, jena.actionUniversalHO, model.getIndividual(selectedIndex), "instanceOf", null);
    }//GEN-LAST:event_actionFOIndividualsMouseClicked

    private void socialCommitmentIndividualsMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_socialCommitmentIndividualsMouseClicked
        int selectedIndex = socialCommitmentIndividuals.getSelectedIndex();
        if (selectedIndex == -1) {
            socialCommitmentDataPanel.setVisible(false);
            return;
        }
        
        socialCommitmentDataPanel.setVisible(true);

        DefaultListModelWithIndividual model = (DefaultListModelWithIndividual) socialCommitmentIndividuals.getModel();
        socialCommitmentName.setText((String) socialCommitmentIndividuals.getSelectedValue());

        Individual ind = model.getIndividual(selectedIndex);
        loadPropertyList(socialCommitmentAgents, jena.socialCommitment, ind, "externalDependency");
        loadComboBox(socialCommitmentAgentCombo, jena.socialCommitment, jena.agent, model.getIndividual(selectedIndex), "externalDependency", null);
        loadComboBox(socialCommitmentActionFO, jena.socialCommitment, jena.actionUniversalFO, model.getIndividual(selectedIndex), "basedOn", null);
        loadComboBox(socialCommitmentResponsable, jena.socialCommitment, null, model.getIndividual(selectedIndex), "basedOn", socialCommitmentAgents);
        loadDate(socialCommitmentIndividuals, jena.socialCommitment, socialCommitmentActualStartCalendar, socialCommitmentActualEndCalendar, "inv-causedBy");
        loadDate(socialCommitmentIndividuals, jena.socialCommitment, socialCommitmentPlannedStartCalendar, socialCommitmentPlannedEndCalendar, "inv-propositionalContentOf");
        defineStatus(socialCommitmentPlannedStartCalendar, socialCommitmentPlannedEndCalendar, socialCommitmentActualStartCalendar, socialCommitmentActualEndCalendar, socialCommitmentStatus, socialCommitmentProgrammedButtonGroup, socialCommitmentProgramed, socialCommitmentStatusButtonGroup, socialCommitmentFulfilled, socialCommitmentDismiss);
    }//GEN-LAST:event_socialCommitmentIndividualsMouseClicked

    private void internalCommitmentIndividualsMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_internalCommitmentIndividualsMouseClicked
        int selectedIndex = internalCommitmentIndividuals.getSelectedIndex();
        if (selectedIndex == -1) {
            internalCommitmentDataPanel.setVisible(false);
            return;
        }
        
        internalCommitmentDataPanel.setVisible(true);

        DefaultListModelWithIndividual model = (DefaultListModelWithIndividual) internalCommitmentIndividuals.getModel();
        internalCommitmentName.setText((String) internalCommitmentIndividuals.getSelectedValue());

        loadComboBox(internalCommitmentAgent, jena.internalCommitment, jena.agent, model.getIndividual(selectedIndex), "inherence", null);
        loadComboBox(internalCommitmentActionFO, jena.internalCommitment, jena.actionUniversalFO, model.getIndividual(selectedIndex), "basedOn", null);
        loadDate(internalCommitmentIndividuals, jena.internalCommitment, internalCommitmentActualStartCalendar, internalCommitmentActualEndCalendar, "inv-causedBy");
        loadDate(internalCommitmentIndividuals, jena.internalCommitment, internalCommitmentPlannedStartCalendar, internalCommitmentPlannedEndCalendar, "inv-propositionalContentOf");
        defineStatus(internalCommitmentPlannedStartCalendar, internalCommitmentPlannedEndCalendar, internalCommitmentActualStartCalendar, internalCommitmentActualEndCalendar, internalCommitmentStatus, internalCommitmentProgrammedButtonGroup, internalCommitmentProgramed, internalCommitmentStatusButtonGroup, internalCommitmentFulfilled, internalCommitmentDismiss);
    }//GEN-LAST:event_internalCommitmentIndividualsMouseClicked

    private void agentIndividualsMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_agentIndividualsMouseClicked
        int selectedIndex = agentIndividuals.getSelectedIndex();
        if (selectedIndex == -1) {
            agentDataPanel.setVisible(false);
            return;
        }
        
        agentDataPanel.setVisible(true);

        DefaultListModelWithIndividual model = (DefaultListModelWithIndividual) agentIndividuals.getModel();
        agentName.setText((String) agentIndividuals.getSelectedValue());

        Individual ind = model.getIndividual(selectedIndex);
        loadPropertyList(agentInternalCommitment, jena.internalCommitment, ind, "inv-inherence");
        loadPropertyList(agentSocialCommitment, jena.socialCommitment, ind, "inv-externalDependency");
    }//GEN-LAST:event_agentIndividualsMouseClicked

    private void actionHOAddMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_actionHOAddMouseClicked
        addButton(jena.actionUniversalHO, "categoria ", COUNTER_ACTIONHO, actionHOIndividuals, actionHOName);
        COUNTER_ACTIONHO++;
        actionHOIndividualsMouseClicked(evt);
        actionHOName.grabFocus();
        actionHOName.setSelectionStart(0);
        actionHOName.setSelectionEnd(actionHOName.getText().length());
    }//GEN-LAST:event_actionHOAddMouseClicked

    private void socialCommitmentAddMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_socialCommitmentAddMouseClicked
        addButton(jena.socialCommitment, "compromisso social ", COUNTER_SOCIALCOMM, socialCommitmentIndividuals, socialCommitmentName);
        COUNTER_SOCIALCOMM++;
        DefaultListModelWithIndividual model = (DefaultListModelWithIndividual) socialCommitmentIndividuals.getModel();
        addDate(jena.socialCommitment, jena.appointmentGoal, model.getIndividual(model.getSize() - 1), "appointmentGoal", "inv-propositionalContentOf");
        addDate(jena.socialCommitment, jena.actionContribution, model.getIndividual(model.getSize() - 1), "actionContribution", "inv-causedBy");
        socialCommitmentUnfulfilledMouseClicked(evt);
        socialCommitmentNonProgramedMouseClicked(evt);
        socialCommitmentIndividualsMouseClicked(evt);
        socialCommitmentName.grabFocus();
        socialCommitmentName.setSelectionStart(0);
        socialCommitmentName.setSelectionEnd(socialCommitmentName.getText().length());
    }//GEN-LAST:event_socialCommitmentAddMouseClicked

    private void internalCommitmentAddMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_internalCommitmentAddMouseClicked
        addButton(jena.internalCommitment, "compromisso pessoal ", COUNTER_INTERNALCOMM, internalCommitmentIndividuals, internalCommitmentName);
        COUNTER_INTERNALCOMM++;
        DefaultListModelWithIndividual model = (DefaultListModelWithIndividual) internalCommitmentIndividuals.getModel();
        addDate(jena.internalCommitment, jena.appointmentGoal, model.getIndividual(model.getSize() - 1), "appointmentGoal", "inv-propositionalContentOf");
        addDate(jena.internalCommitment, jena.actionContribution, model.getIndividual(model.getSize() - 1), "actionContribution", "inv-causedBy");
        internalCommitmentUnfulfilledMouseClicked(evt);
        internalCommitmentNonProgramedMouseClicked(evt);
        internalCommitmentIndividualsMouseClicked(evt);
        internalCommitmentName.grabFocus();
        internalCommitmentName.setSelectionStart(0);
        internalCommitmentName.setSelectionEnd(internalCommitmentName.getText().length());
    }//GEN-LAST:event_internalCommitmentAddMouseClicked

    private void agentAddMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_agentAddMouseClicked
        addButton(jena.agent, "pessoa ", COUNTER_AGENT, agentIndividuals, agentName);
        COUNTER_AGENT++;
        agentIndividualsMouseClicked(evt);
        agentName.grabFocus();
        agentName.setSelectionStart(0);
        agentName.setSelectionEnd(agentName.getText().length());
    }//GEN-LAST:event_agentAddMouseClicked

    private void actionFOAddMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_actionFOAddMouseClicked
        addButton(jena.actionUniversalFO, "evento ", COUNTER_ACTIONFO, actionFOIndividuals, actionFOName);
        COUNTER_ACTIONFO++;
        actionFOIndividualsMouseClicked(evt);
        actionFOName.grabFocus();
        actionFOName.setSelectionStart(0);
        actionFOName.setSelectionEnd(actionFOName.getText().length());
    }//GEN-LAST:event_actionFOAddMouseClicked

    private void formWindowClosing(java.awt.event.WindowEvent evt) {//GEN-FIRST:event_formWindowClosing
        fileExitActionPerformed(null);
    }//GEN-LAST:event_formWindowClosing

    private void internalCommitmentNonProgramedMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_internalCommitmentNonProgramedMouseClicked
        internalCommitmentPlannedStartCalendar.setEnabled(false);
        internalCommitmentPlannedEndCalendar.setEnabled(false);
        internalCommitmentProgrammedButtonGroup.setSelected(internalCommitmentNonProgramed.getModel(), true);
    }//GEN-LAST:event_internalCommitmentNonProgramedMouseClicked

    private void internalCommitmentProgramedMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_internalCommitmentProgramedMouseClicked
        internalCommitmentPlannedStartCalendar.setEnabled(true);
        internalCommitmentPlannedEndCalendar.setEnabled(true);
    }//GEN-LAST:event_internalCommitmentProgramedMouseClicked

    private void socialCommitmentNonProgramedMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_socialCommitmentNonProgramedMouseClicked
        socialCommitmentPlannedStartCalendar.setEnabled(false);
        socialCommitmentPlannedEndCalendar.setEnabled(false);
        socialCommitmentProgrammedButtonGroup.setSelected(socialCommitmentNonProgramed.getModel(), true);
    }//GEN-LAST:event_socialCommitmentNonProgramedMouseClicked

    private void socialCommitmentProgramedMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_socialCommitmentProgramedMouseClicked
        socialCommitmentPlannedStartCalendar.setEnabled(true);
        socialCommitmentPlannedEndCalendar.setEnabled(true);
    }//GEN-LAST:event_socialCommitmentProgramedMouseClicked

    private void fileOpenActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_fileOpenActionPerformed
        int result = fc.showOpenDialog(this);
        
        switch (result) {
            case JFileChooser.APPROVE_OPTION:
                selFile = fc.getSelectedFile();
                setOntLoaded(true, false);
                break;
            case JFileChooser.CANCEL_OPTION:
                break;
            case JFileChooser.ERROR_OPTION:
                System.out.println("Error while openning a file.");
                break;
        }   
}//GEN-LAST:event_fileOpenActionPerformed

    private void fileSaveActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_fileSaveActionPerformed
        if(isOntLoaded() == true){
            if(isOntSaved() == false){
                fileSaveAsActionPerformed(evt);
            }
            else{
                jena.saveOntology(selFile);
            }
        }
}//GEN-LAST:event_fileSaveActionPerformed

    private void fileSaveAsActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_fileSaveAsActionPerformed
        if(isOntLoaded() == true){
            int result = fc.showSaveDialog(this);

            switch (result) {
                case JFileChooser.APPROVE_OPTION:
                    selFile = fc.getSelectedFile();
                    jena.saveOntology(selFile);
                    break;
                case JFileChooser.CANCEL_OPTION:
                    break;
                case JFileChooser.ERROR_OPTION:
                    System.out.println("Error while saving a file.");
                    break;
            } 
        } 
}//GEN-LAST:event_fileSaveAsActionPerformed

    private void fileNewActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_fileNewActionPerformed
        setOntLoaded(true, true);
}//GEN-LAST:event_fileNewActionPerformed

    private void TabWindowMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_TabWindowMouseClicked
        reloadAllTabs();
    }//GEN-LAST:event_TabWindowMouseClicked

    private void agentNameKeyReleased(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_agentNameKeyReleased
        agentSaveMouseClicked(null);
    }//GEN-LAST:event_agentNameKeyReleased

    private void internalCommitmentNameKeyReleased(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_internalCommitmentNameKeyReleased
        internalCommitmentSaveMouseClicked(null);
    }//GEN-LAST:event_internalCommitmentNameKeyReleased

    private void socialCommitmentNameKeyReleased(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_socialCommitmentNameKeyReleased
        socialCommitmentSaveMouseClicked(null);
    }//GEN-LAST:event_socialCommitmentNameKeyReleased

    private void actionFONameKeyReleased(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_actionFONameKeyReleased
        actionFOSaveMouseClicked(null);
    }//GEN-LAST:event_actionFONameKeyReleased

    private void actionHONameKeyReleased(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_actionHONameKeyReleased
        actionHOSaveMouseClicked(null);
    }//GEN-LAST:event_actionHONameKeyReleased

    private void fileCloseFileActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_fileCloseFileActionPerformed
        if(isOntLoaded() == true){
            setOntLoaded(false, false);
        }
    }//GEN-LAST:event_fileCloseFileActionPerformed

    private void fileExitActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_fileExitActionPerformed
        System.exit(0);
    }//GEN-LAST:event_fileExitActionPerformed

    /**
     * @param args the command line arguments
     */
    public static void main(String args[]) {
        java.awt.EventQueue.invokeLater(new Runnable() {

            public void run() {
                new MainWindow().setVisible(true);
            }
        });
    }
    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JTabbedPane TabWindow;
    private javax.swing.JComboBox actionFOActionHO;
    private javax.swing.JButton actionFOAdd;
    private javax.swing.JPanel actionFODataPanel;
    private javax.swing.JList actionFOIndividuals;
    private javax.swing.JPanel actionFOInnerPannel;
    private javax.swing.JList actionFOInternalCommitment;
    private javax.swing.JTextField actionFOName;
    private javax.swing.JPanel actionFOPanel;
    private javax.swing.JButton actionFOSave;
    private javax.swing.JList actionFOSocialCommitment;
    private javax.swing.JList actionHOActionFO;
    private javax.swing.JButton actionHOAdd;
    private javax.swing.JPanel actionHODataPanel;
    private javax.swing.JList actionHOIndividuals;
    private javax.swing.JPanel actionHOInnerPanel;
    private javax.swing.JTextField actionHOName;
    private javax.swing.JPanel actionHOPanel;
    private javax.swing.JButton actionHOSave;
    private javax.swing.JButton agentAdd;
    private javax.swing.JPanel agentDataPanel;
    private javax.swing.JList agentIndividuals;
    private javax.swing.JPanel agentInnerPanel;
    private javax.swing.JList agentInternalCommitment;
    private javax.swing.JTextField agentName;
    private javax.swing.JPanel agentPanel;
    private javax.swing.JButton agentSave;
    private javax.swing.JList agentSocialCommitment;
    private javax.swing.JMenuItem fileCloseFile;
    private javax.swing.JMenuItem fileExit;
    private javax.swing.JMenuItem fileNew;
    private javax.swing.JMenuItem fileOpen;
    private javax.swing.JMenuItem fileSave;
    private javax.swing.JMenuItem fileSaveAs;
    private javax.swing.JPanel internalCommPanel;
    private javax.swing.JComboBox internalCommitmentActionFO;
    private com.toedter.calendar.JDateChooser internalCommitmentActualEndCalendar;
    private com.toedter.calendar.JDateChooser internalCommitmentActualStartCalendar;
    private javax.swing.JButton internalCommitmentAdd;
    private javax.swing.JComboBox internalCommitmentAgent;
    private javax.swing.JPanel internalCommitmentDataPanel;
    private javax.swing.JCheckBox internalCommitmentDismiss;
    private javax.swing.JRadioButton internalCommitmentFulfilled;
    private javax.swing.JList internalCommitmentIndividuals;
    private javax.swing.JPanel internalCommitmentInnerPanel;
    private javax.swing.JTextField internalCommitmentName;
    private javax.swing.JRadioButton internalCommitmentNonProgramed;
    private com.toedter.calendar.JDateChooser internalCommitmentPlannedEndCalendar;
    private com.toedter.calendar.JDateChooser internalCommitmentPlannedStartCalendar;
    private javax.swing.JRadioButton internalCommitmentProgramed;
    private javax.swing.ButtonGroup internalCommitmentProgrammedButtonGroup;
    private javax.swing.JButton internalCommitmentSave;
    private javax.swing.JLabel internalCommitmentStatus;
    private javax.swing.ButtonGroup internalCommitmentStatusButtonGroup;
    private javax.swing.JRadioButton internalCommitmentUnfulfilled;
    private javax.swing.JLabel jLabel1;
    private javax.swing.JLabel jLabel10;
    private javax.swing.JLabel jLabel11;
    private javax.swing.JLabel jLabel12;
    private javax.swing.JLabel jLabel13;
    private javax.swing.JLabel jLabel14;
    private javax.swing.JLabel jLabel15;
    private javax.swing.JLabel jLabel16;
    private javax.swing.JLabel jLabel17;
    private javax.swing.JLabel jLabel18;
    private javax.swing.JLabel jLabel19;
    private javax.swing.JLabel jLabel2;
    private javax.swing.JLabel jLabel20;
    private javax.swing.JLabel jLabel21;
    private javax.swing.JLabel jLabel22;
    private javax.swing.JLabel jLabel23;
    private javax.swing.JLabel jLabel24;
    private javax.swing.JLabel jLabel25;
    private javax.swing.JLabel jLabel26;
    private javax.swing.JLabel jLabel27;
    private javax.swing.JLabel jLabel28;
    private javax.swing.JLabel jLabel29;
    private javax.swing.JLabel jLabel3;
    private javax.swing.JLabel jLabel30;
    private javax.swing.JLabel jLabel4;
    private javax.swing.JLabel jLabel5;
    private javax.swing.JLabel jLabel6;
    private javax.swing.JLabel jLabel7;
    private javax.swing.JLabel jLabel8;
    private javax.swing.JLabel jLabel9;
    private javax.swing.JMenu jMenu1;
    private javax.swing.JMenuBar jMenuBar1;
    private javax.swing.JMenuItem jMenuItem4;
    private javax.swing.JMenuItem jMenuItem5;
    private javax.swing.JProgressBar jProgressBar1;
    private javax.swing.JProgressBar jProgressBar2;
    private javax.swing.JProgressBar jProgressBar3;
    private javax.swing.JScrollPane jScrollPane1;
    private javax.swing.JScrollPane jScrollPane10;
    private javax.swing.JScrollPane jScrollPane13;
    private javax.swing.JScrollPane jScrollPane14;
    private javax.swing.JScrollPane jScrollPane2;
    private javax.swing.JScrollPane jScrollPane3;
    private javax.swing.JScrollPane jScrollPane4;
    private javax.swing.JScrollPane jScrollPane5;
    private javax.swing.JScrollPane jScrollPane6;
    private javax.swing.JScrollPane jScrollPane7;
    private javax.swing.JScrollPane jScrollPane8;
    private javax.swing.JSeparator jSeparator1;
    private javax.swing.JSeparator jSeparator2;
    private javax.swing.JSeparator jSeparator3;
    private javax.swing.JSeparator jSeparator4;
    private javax.swing.JSeparator jSeparator5;
    private javax.swing.JScrollPane scrollAgent;
    private javax.swing.JScrollPane scrollAgent1;
    private javax.swing.JScrollPane scrollAgent2;
    private javax.swing.JScrollPane scrollAgent3;
    private javax.swing.JScrollPane scrollAgent4;
    private javax.swing.JPanel socialCommPanel;
    private javax.swing.JComboBox socialCommitmentActionFO;
    private com.toedter.calendar.JDateChooser socialCommitmentActualEndCalendar;
    private com.toedter.calendar.JDateChooser socialCommitmentActualStartCalendar;
    private javax.swing.JButton socialCommitmentAdd;
    private javax.swing.JButton socialCommitmentAgentAdd;
    private javax.swing.JComboBox socialCommitmentAgentCombo;
    private javax.swing.JButton socialCommitmentAgentRemove;
    private javax.swing.JList socialCommitmentAgents;
    private javax.swing.JPanel socialCommitmentDataPanel;
    private javax.swing.JCheckBox socialCommitmentDismiss;
    private javax.swing.JRadioButton socialCommitmentFulfilled;
    private javax.swing.JList socialCommitmentIndividuals;
    private javax.swing.JPanel socialCommitmentInnerPanel;
    private javax.swing.JTextField socialCommitmentName;
    private javax.swing.JRadioButton socialCommitmentNonProgramed;
    private com.toedter.calendar.JDateChooser socialCommitmentPlannedEndCalendar;
    private com.toedter.calendar.JDateChooser socialCommitmentPlannedStartCalendar;
    private javax.swing.JRadioButton socialCommitmentProgramed;
    private javax.swing.ButtonGroup socialCommitmentProgrammedButtonGroup;
    private javax.swing.JComboBox socialCommitmentResponsable;
    private javax.swing.JButton socialCommitmentSave;
    private javax.swing.JLabel socialCommitmentStatus;
    private javax.swing.ButtonGroup socialCommitmentStatusButtonGroup;
    private javax.swing.JRadioButton socialCommitmentUnfulfilled;
    // End of variables declaration//GEN-END:variables
}

